package com.comando.model;

import java.sql.Timestamp;
import java.util.Date;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import org.hibernate.annotations.GenericGenerator;

/**
 * UserInfoT entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "user_info_t", catalog = "qunar")
public class UserInfoT implements java.io.Serializable {

	// Fields

	private Integer userInfoId;
	private UserT userT;
	private String address;
	private Date birthday;
	private Timestamp createTime;
	private String nickName;
	private String fax;
	private Boolean gender;
	private String mobile;
	private Timestamp modifyTime;
	private String realName;
	private String state;
	private String tel;
	private String zip;

	// Constructors

	/** default constructor */
	public UserInfoT() {
	}

	/** minimal constructor */
	public UserInfoT(UserT userT, String nickName, String state) {
		this.userT = userT;
		this.nickName = nickName;
		this.state = state;
	}

	/** full constructor */
	public UserInfoT(UserT userT, String address, Date birthday,
			Timestamp createTime, String nickName, String fax, Boolean gender,
			String mobile, Timestamp modifyTime, String realName, String state,
			String tel, String zip) {
		this.userT = userT;
		this.address = address;
		this.birthday = birthday;
		this.createTime = createTime;
		this.nickName = nickName;
		this.fax = fax;
		this.gender = gender;
		this.mobile = mobile;
		this.modifyTime = modifyTime;
		this.realName = realName;
		this.state = state;
		this.tel = tel;
		this.zip = zip;
	}

	// Property accessors
	@GenericGenerator(name = "generator", strategy = "increment")
	@Id
	@GeneratedValue(generator = "generator")
	@Column(name = "USER_INFO_ID", unique = true, nullable = false)
	public Integer getUserInfoId() {
		return this.userInfoId;
	}

	public void setUserInfoId(Integer userInfoId) {
		this.userInfoId = userInfoId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "USER_ID", nullable = false)
	public UserT getUserT() {
		return this.userT;
	}

	public void setUserT(UserT userT) {
		this.userT = userT;
	}

	@Column(name = "ADDRESS", length = 250)
	public String getAddress() {
		return this.address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	@Temporal(TemporalType.DATE)
	@Column(name = "BIRTHDAY", length = 10)
	public Date getBirthday() {
		return this.birthday;
	}

	public void setBirthday(Date birthday) {
		this.birthday = birthday;
	}

	@Column(name = "CREATE_TIME", length = 19)
	public Timestamp getCreateTime() {
		return this.createTime;
	}

	public void setCreateTime(Timestamp createTime) {
		this.createTime = createTime;
	}

	@Column(name = "NICK_NAME", nullable = false, length = 50)
	public String getNickName() {
		return this.nickName;
	}

	public void setNickName(String nickName) {
		this.nickName = nickName;
	}

	@Column(name = "FAX", length = 250)
	public String getFax() {
		return this.fax;
	}

	public void setFax(String fax) {
		this.fax = fax;
	}

	@Column(name = "GENDER")
	public Boolean getGender() {
		return this.gender;
	}

	public void setGender(Boolean gender) {
		this.gender = gender;
	}

	@Column(name = "MOBILE", length = 250)
	public String getMobile() {
		return this.mobile;
	}

	public void setMobile(String mobile) {
		this.mobile = mobile;
	}

	@Column(name = "MODIFY_TIME", length = 19)
	public Timestamp getModifyTime() {
		return this.modifyTime;
	}

	public void setModifyTime(Timestamp modifyTime) {
		this.modifyTime = modifyTime;
	}

	@Column(name = "REAL_NAME", length = 50)
	public String getRealName() {
		return this.realName;
	}

	public void setRealName(String realName) {
		this.realName = realName;
	}

	@Column(name = "STATE", nullable = false, length = 2)
	public String getState() {
		return this.state;
	}

	public void setState(String state) {
		this.state = state;
	}

	@Column(name = "TEL", length = 250)
	public String getTel() {
		return this.tel;
	}

	public void setTel(String tel) {
		this.tel = tel;
	}

	@Column(name = "ZIP", length = 20)
	public String getZip() {
		return this.zip;
	}

	public void setZip(String zip) {
		this.zip = zip;
	}

}